/*
 * @Author: your name
 * @Date: 2022-01-11 14:16:53
 * @LastEditTime: 2022-01-25 16:28:16
 * @LastEditors: Please set LastEditors
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AET
 * @FilePath: \xy-web-xiaoxi\src\api\rs\bom.js
 */

import request from '@/utils/request'

/**
 * @description:新增
 * @param {*} data
 * @return {*}
 */
export function saveBom(data) {
  return request({
    url: '/api/base/bom/save',
    method: 'post',
    data
  })
}

/**
 * @description: 更新
 * @param {*} data
 * @return {*}
 */
export function updateBom(data) {
  return request({
    url: '/api/base/bom/update',
    method: 'post',
    data
  })
}

/**
 * @description: 获取
 * @param {*} data
 * @return {*}
 */
export function pageBom(data) {
  return request({
    url: '/api/base/bom/page',
    method: 'post',
    data
  })
}

export function auditCommonFlowApplyBom(data) {
  return request({
    url: '/api/base/audit_common_flow/apply',
    method: 'post',
    data
  })
}

/**
 * @description: 复制
 * @param {*} data
 * @return {*}
 */
export function copyBom(data) {
  return request({
    url: '/api/base/bom/copy',
    method: 'post',
    data
  })
}
/**
 * @description: 删除
 * @param {*} data
 * @return {*}
 */
export function deleteBom(data) {
  return request({
    url: '/api/base/bom/delete',
    method: 'post',
    data
  })
}
/**
 * @description: 配置信息
 * @param {*} data
 * @return {*}
 */
export function bomListPreOptions(data) {
  return request({
    url: '/api/base/bom/list_pre_options',
    method: 'get'
  })
}
